package org.apache.calcite.sql.ddl;

import org.apache.calcite.sql.SqlDialect;
import org.apache.calcite.sql.SqlWriterConfig;
import org.apache.calcite.sql.pretty.SqlPrettyWriter;

public class MySqlPrettyWriter extends SqlPrettyWriter {
    public MySqlPrettyWriter(SqlWriterConfig config) {
        super(config);
    }

    public  void primary(){
//        MyTestDialect dialect = getDialect();
        if(getDialect() instanceof MyTestDialect ){
            String primary = ((MyTestDialect)getDialect()).primary();
            keyword(primary);
        }else {
            keyword("primary key");
        }


    }
}
